Autonomous preoperative rehabilitation exercises